Skip to content

Fix Task Instance mark-as downstream default#67763

Open
Codingaditya17 wants to merge 1 commit into
apache:mainfrom
Codingaditya17:fix-ti-mark-success-no-downstream-resume
Open

Fix Task Instance mark-as downstream default#67763
Codingaditya17 wants to merge 1 commit into
apache:mainfrom
Codingaditya17:fix-ti-mark-success-no-downstream-resume

Conversation

@Codingaditya17
Copy link
Copy Markdown
Contributor

What

This PR updates the Task Instance mark-as dialog so that the downstream option is no longer selected by default.

Why

In the Task Instances view, marking a failed task instance as success should not automatically include downstream task instances unless the user explicitly selects that option.

Previously, the dialog defaulted to downstream, which meant the request was sent with include_downstream: true. This could cause downstream upstream_failed task instances to be affected and resume within the same DagRun, which differs from the older Airflow 2 Task Instances view behavior.

This change makes the action safer and more explicit: only the selected task instance is updated by default, while users can still choose downstream manually when they want that behavior.

How

  • Removed the default downstream selection from MarkTaskInstanceAsDialog
  • Added a regression test to verify that downstream is not selected by default

Tests

cd airflow-core/src/airflow/ui
pnpm test MarkTaskInstanceAsDialog.test.tsx

Result:
✓ src/components/MarkAs/TaskInstance/MarkTaskInstanceAsDialog.test.tsx (1 test) 123ms
✓ MarkTaskInstanceAsDialog (1)
✓ does not select downstream by default 120ms

Test Files 1 passed (1)
Tests 1 passed (1)

uv run prek run ts-compile-lint-ui --all-files

Result:
Running hooks for airflow-core:
Compile / format / lint UI...............................................Passed

@boring-cyborg boring-cyborg Bot added the area:UI Related to UI/UX. For Frontend Developers. label May 30, 2026
@Codingaditya17 Codingaditya17 force-pushed the fix-ti-mark-success-no-downstream-resume branch from 46ddfd7 to f9907be Compare May 30, 2026 15:16
@potiuk potiuk added the ready for maintainer review Set after triaging when all criteria pass. label Jun 1, 2026
@bbovenzi
Copy link
Copy Markdown
Contributor

bbovenzi commented Jun 1, 2026

I removed the default before and some users were upset. So I think we should introduce a config option for admins to decide for themselves.

@pierrejeambrun
Copy link
Copy Markdown
Member

I was wondering if we should have a 'user settings' (UI only / localstorage) that would allow people to configure that locally. The goal would be to not have 'UI config' globally applied returned by the backend for those "UI settings"

@Codingaditya17
Copy link
Copy Markdown
Contributor Author

Thanks for the clarification.

I can update this PR in that direction. Before I make the change, I wanted to confirm the preferred scope.

Would you prefer this to be:

  1. A local UI preference saved in browser local storage, so each user can choose whether downstream is selected by default in the Task Instance mark-as dialog.

  2. A global Airflow config option controlled by admins, so the default is consistent for all users in an environment.

My understanding from the discussion is that a local UI setting may be lighter and avoids adding backend config just for this UI preference, but I am happy to follow whichever direction maintainers prefer.

@bbovenzi , @pierrejeambrun

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:UI Related to UI/UX. For Frontend Developers. ready for maintainer review Set after triaging when all criteria pass.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants